package com.yanmaohu.yulia.statement;

import com.yanmaohu.yulia.bean.AlterRoutineBehavior;
import com.yanmaohu.yulia.bean.AlterRoutineCharacteristics;
import com.yanmaohu.yulia.bean.SpecificRoutineDesignator;

/**
 * @author Bright Lee
 */
public final class AlterRoutineStatement implements SqlSchemaManipulationStatement {

    private int beginIndex;
    private int endIndex;
    private SpecificRoutineDesignator specificRoutineDesignator;
    private AlterRoutineCharacteristics alterRoutineCharacteristics;
    private AlterRoutineBehavior alterRoutineBehavior;

    public AlterRoutineStatement(int beginIndex, SpecificRoutineDesignator specificRoutineDesignator, AlterRoutineCharacteristics alterRoutineCharacteristics, AlterRoutineBehavior alterRoutineBehavior) {
        this.beginIndex = beginIndex;
        this.endIndex = alterRoutineBehavior.getEndIndex();
        this.specificRoutineDesignator = specificRoutineDesignator;
        this.alterRoutineCharacteristics = alterRoutineCharacteristics;
        this.alterRoutineBehavior = alterRoutineBehavior;
    }

    @Override
    public int getBeginIndex() {
        return beginIndex;
    }

    @Override
    public int getEndIndex() {
        return endIndex;
    }

    public SpecificRoutineDesignator getSpecificRoutineDesignator() {
        return specificRoutineDesignator;
    }

    public AlterRoutineCharacteristics getAlterRoutineCharacteristics() {
        return alterRoutineCharacteristics;
    }

    public AlterRoutineBehavior getAlterRoutineBehavior() {
        return alterRoutineBehavior;
    }

}
